package com.kgc.ljp.util;

import com.kgc.ljp.entity.Flight;

import java.text.ParseException;
import java.text.SimpleDateFormat;
import java.util.Date;
import java.util.HashMap;
import java.util.Map;

public class Initi {
    static Flight flight = new Flight();
    public static Map<String,Flight> flightMap = new HashMap<>();
    static SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd");
    static {
        try {
            flight = new Flight("001","杭州","成都",sdf.parse("2018-10-20"),1600,30);
        } catch (ParseException e) {
            e.printStackTrace();
        }
        flightMap.put(flight.getaNo(),flight);
    }
}
